<?php if (!defined('THINK_PATH')) exit();?><!doctype html>
<html>
<head>
<meta charset="UTF-8"/>
<title>运营平台</title>
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
<meta name="renderer" content="webkit">
<!--<meta http-equiv="X-UA-Compatible" content="IE=edge">-->
<link type="text/css" rel="stylesheet" href="<?php echo get_style_cdnurl();?>paimai/yunying/css/common.css?v=20170207" />
<link type="text/css" rel="stylesheet" href="<?php echo get_style_cdnurl();?>paimai/yunying/css/table.css?v=20170117" />
<link type="text/css" rel="stylesheet" href="<?php echo get_style_cdnurl();?>paimai/yunying/css/jquery-ui.css" />
<script src="<?php echo get_style_cdnurl();?>paimai/yunying/js/jquery-1.11.1.js" type="text/javascript"></script>
<script src="<?php echo get_style_cdnurl();?>paimai/yunying/js/jquery-ui.min.js" type="text/javascript"></script>
 <script src="<?php echo get_style_cdnurl();?>paimai/yunying/js/yunIndex.js" type="text/javascript"></script>
<script src="<?php echo get_style_cdnurl();?>paimai/yunying/js/jquery-ym-datePlugin-0.1.js" type="text/javascript"></script>
<script src="<?php echo get_style_cdnurl();?>paimai/yunying/js/global.js" type="text/javascript"></script>
<script src="<?php echo get_style_cdnurl();?>paimai/cheshan/js/common.js" type="text/javascript"></script>
<script type="text/javascript" src="<?php echo get_style_cdnurl();?>paimai/yunying/js/jquery.placeholder.min.js"></script>
<script type="text/javascript">
 $(function(){
     $("input").placeholder();
     if (navigator.userAgent.indexOf("Safari") > -1) {
       $("input").css("lineHeight","normal !important");
     };
});
</script>

<style type="text/css">
    .car_info{margin:10px 20px;}
    .car_info .car_no{width:100%;height:25px;margin-bottom:10px;}
    .car_info table tr td{height:30px;text-align:left;font-size:12px;padding-left:10px;}
    .clear{clear:both;}
</style>
</head>
<body>
<div class="header">
<div class="headerCo">
<span>你好,<?php echo ($user_info["real_name"]); ?><a href="<?php echo (WEB_URL); ?>Emp/logout">退出</a></span>
<h1><img src="<?php echo get_style_cdnurl();?>paimai/yunying/images/yun_logo.jpg"></h1>
</div>
</div>
<div class="mian">
<div class="mianL">
    <dl>
        <dd>
            <a id="menu_sy" href="/Index/index" class="shouye">首页</a>
        </dd>
        <?php foreach ($tree_menu as $key => $value): ?>
          <dd>
            <span id="menu_<?php echo ($value['first_char']); ?>" ><img src="<?php echo get_style_cdnurl();?>paimai/yunying/images/yun_jia.jpg"><?php echo ($value['name']); ?></span>
            <ul style="display: none;">
                <?php if (!empty($value['children'])): ?>
                    <?php foreach ($value['children'] as $k => $v): ?>
                        <li><a id='menu_<?php echo ($v["first_char"]); ?>' href="<?php echo ($v['url']); ?>"><?php echo ($v['name']); ?></a></li>
                    <?php endforeach ?>
                <?php endif ?>
            </ul>
        <?php endforeach ?>
    </dl>
</div>

<?php $menu = 'cxtj.clcx'; ?>
<?php $menu=json_encode(explode('.', $menu)); ?>
<script>
    $(function () {
        var cur_menu = '<?php echo ($menu); ?>', cur_menu = eval('[' + cur_menu + ']'), cur_menu = cur_menu[0];
        if (cur_menu == "sy") {
            $("#menu_sy").removeClass('shouye').addClass('current');
        }
        $('#menu_' + cur_menu[0]).click();
        $('#menu_' + cur_menu[0]).find("img").attr("src", "http://img1.isou365.cn/paimai/yunying/images/yun_jie.jpg");
        $(".mianL").css("height", $(document).height() - 95);
        $('#menu_' + cur_menu[1]).addClass('current');
    });
</script>
    <div class="mianR">
        <div class="yuyue">
            <ul>
                <li class="yuCurrent">基本信息</li>
                <li>车辆状态跟踪</li>
                <li id="history">历史检测报告</li>
            </ul>
        </div>
        <div class='listBox'>
            <div class="yuList" >
<!--                <h3 class='cha'>基本信息</h3>-->
                <div class='car_info'>
                    <div class='car_no'><span style="font-size:14px;">车辆编号：<b><?php echo ($car_info["sno"]); ?></b></span></div>
                    <table border='1' width='100%'>
                         <tbody>
                            <td colspan='4' style="background-color:#c1c1c1;font-size:14px;"><span>车主信息</span></td>
                            <tr>
                                <td width="11%" style="color:#898b8a;">车主类型</td>
                                <td width="39%"><?php echo ($owner["owner_type_name"]); ?></td>
                                <?php if($owner["owner_type"] == 1): ?><td width="11%" style="color:#898b8a;">车主姓名</td>
                                    <td width="39%"><?php echo ($owner["seller_name"]); ?></td>
                                    <?php else: ?>
                                    <td width="11%" style="color:#898b8a;">公司名称</td>
                                    <td width="39%"><?php echo ($owner["seller_name"]); ?></td><?php endif; ?>
                            </tr>
                            <tr>
                                <?php if($owner["owner_type"] == 1): ?><td width="11%" style="color:#898b8a;">联系电话</td>
                                    <td colspan="3"><?php echo ($owner["phone"]); ?></td>
                                    <?php else: ?>
                                    <td width="11%" style="color:#898b8a;">联系人姓名</td>
                                    <td width="39%"><?php echo ($owner["contact_person"]); ?></td>
                                    <td width="11%" style="color:#898b8a;">联系电话</td>
                                    <td width="39%"><?php echo ($owner["phone"]); ?></td><?php endif; ?>
                            </tr>
                         </tbody>
                    </table>
                    <table border='1' width='100%' style="margin-top:20px;">
                         <tbody>
                            <tr  style="background-color:#c1c1c1;font-size:14px;">
                                <td colspan='4'><span>车辆信息</span></td>
                                <!--<td>
                                    <a href="/Car/report/car_id/<?php echo ($car_info["car_id"]); ?>" target="_blank">
                                        <span style="float:right;padding-right: 10%;color:#20ab4f;">检测报告</span>
                                    </a>
                                </td>-->
                            </tr>
                            <tr>
                                <td width="11%" style="color:#898b8a;">车型</td>
                                <td width="39%"><?php echo ($car_info["model"]); ?></td>
                                <td width="11%" style="color:#898b8a;">排放标准</td>
                                <td width="39%"><?php echo ($car_info["mession"]); ?></td>
                            </tr>
                            <tr>
                                <td style="color:#898b8a;">初登日期</td>
                                <td><?php echo ($car_info["first_reg_date"]); ?></td>
                                <td style="color:#898b8a;">颜色</td>
                                <td><?php echo ($car_info["color"]); ?></td>
                            </tr>
                            <tr>
                                <td style="color:#898b8a;">表显里程</td>
                                <td><?php echo ($car_info["pointer_mileage"]); ?></td>
                                <td style="color:#898b8a;">车况级别</td>
                                <td><?php echo ($car_info["car_level"]); ?></td>
                            </tr>
                            <tr>
                                <td style="color:#898b8a;">车辆注册地</td>
                                <td><?php echo ($car_info["reg_city"]); ?></td>
                                <td style="color:#898b8a;">车架号</td>
                                <td><?php echo ($car_info["car_vin"]); ?></td>
                            </tr>
                            <tr>
                                <td style="color:#898b8a;">车牌号</td>
                                <td><?php echo ($car_info["car_plate_number"]); ?></td>
                                <?php $transfer_type = array('1'=>'必须过本地','2'=>'必须过外户','3'=>'不限制'); ?>
                                <td style="color:#898b8a;">过户限制</td>
                                <td><?php echo ($transfer_type[$car_info['transfer_limit']]); ?></td>
                            </tr>
                            <tr>
                                <td style="color:#898b8a;">渠道来源</td>
                                <td>
                                    <?php if($car_info["comefrom"] != ''): if(empty($car_info['comefrom_url'])):?>
                                      <?php echo $show_from[$car_info['comefrom']];?>
                                    <?php else: ?>
                                      <a href="<?php echo ($car_info["comefrom_url"]); ?>" target="_blank" rel="noreferrer"><?php echo $show_from[$car_info['comefrom']];?></a>
                                    <?php endif;?>
                                  <?php else: ?>
                                      未知<?php endif; ?>
                                </td>
                                <td style="color:#898b8a;">所在地</td>
                                <td><?php echo ($car_info["location_area"]); ?></td>
                            </tr>
                         </tbody>
                    </table> 

                     <?php $order_type = array('0'=>'顺序拍','1'=>'定时拍') ?>
                     <?php if(is_array($order_list)): $i = 0; $__LIST__ = $order_list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$ol): $mod = ($i % 2 );++$i; if($ol["is_other_channel_deal"] == 1): ?><div class='car_no' style="margin-top:20px;"><span style="font-size:14px;" >订单编号：<b><?php echo ($ol["order_no"]); ?></b></span></div>
                             <table border='1' width='100%'>
                                 <tbody>
                                 <tr>
                                     <td colspan='3' style="background-color:#c1c1c1;font-size:14px;">
                                         <span>订单信息</span>
                                     </td>
                                     <td style="background-color:#c1c1c1;font-size:14px;">
                                         <a href="/Car/report/car_id/<?php echo ($ol["car_id"]); ?>" target="_blank">
                                             <span style="float:right;padding-right: 10%;color:#20ab4f;">检测报告</span>
                                         </a>
                                     </td>
                                 <tr>
                                     <td width="11%" style="color:#898b8a;">订单价格</td>
                                     <td width="39%"><?php echo ($ol["order_amount"]); ?></td>
                                     <td width="11%" style="color:#898b8a;">收款单号</td>
                                     <td width="39%"><?php echo ($ol["collection_no"]); ?></td>
                                 </tr>
                                 <tr>
                                     <td width="11%" style="color:#898b8a;">交易佣金</td>
                                     <td width="39%"><?php echo ($ol["transfer_fee"]); ?></td>
                                     <td width="11%" style="color:#898b8a;">采购单号</td>
                                     <td width="39%"><?php echo ($ol["purchase_order_nu"]); ?></td>
                                 </tr>
                                 <tr>
                                     <td width="11%" style="color:#898b8a;">订单生成时间</td>
                                     <td colspan="3" width="89%"><?php echo ($ol["create_time"]); ?></td>
                                 </tr>
                                 </tbody>
                             </table>
                         <?php else: ?>
                             <div class='car_no' style="margin-top:20px;"><span style="font-size:14px;" >拍卖单号：<b><?php echo ($ol["order_no"]); ?></b></span></div>
                             <table border='1' width='100%'>
                                 <tbody>
                                 <tr>
                                     <td colspan='3' style="background-color:#c1c1c1;font-size:14px;">
                                         <span>拍单信息</span>
                                     </td>
                                     <td style="background-color:#c1c1c1;font-size:14px;">
                                         <a href="/Car/report/car_id/<?php echo ($ol["car_id"]); ?>" target="_blank">
                                             <span style="float:right;padding-right: 10%;color:#20ab4f;">检测报告</span>
                                         </a>
                                     </td>
                                 <tr>
                                     <td width="11%" style="color:#898b8a;">上拍场次</td>
                                     <td width="39%"><?php echo ($ol["scene_name"]); ?></td>
                                     <td width="11%" style="color:#898b8a;">竞拍方式</td>
                                     <td width="39%"><?php echo ($order_type[$ol['is_timing_order']]); ?></td>
                                 </tr>
                                 <tr>
                                     <td style="color:#898b8a;">竞拍时长</td>
                                     <td><?php echo ($ol["est_elapsed_time"]); ?></td>
                                     <td style="color:#898b8a;">竞拍开始时间</td>
                                     <td><?php echo ($ol["bidding_start_time"]); ?></td>
                                 </tr>
                                 <tr>
                                     <td style="color:#898b8a;">起拍价</td>
                                     <td><?php echo ($ol["bid_start_price"]); ?></td>
                                     <td style="color:#898b8a;">竞拍结束时间</td>
                                     <td><?php echo ($ol["bidding_end_time"]); ?></td>
                                 </tr>
                                 <tr>
                                     <td style="color:#898b8a;">建议价</td>
                                     <td><?php echo ($car_info["suggest_min_price"]); ?> - <?php echo ($car_info["suggest_max_price"]); ?></td>
                                     <td style="color:#898b8a;">可用代金券</td>
                                     <td><?php echo ($ol["coupon"]); ?></td>
                                 </tr>
                                 <tr>

                                     <td style="color:#898b8a;">保留价</td>
                                     <td>
                                         <?php echo ($ol["reserve_price"]); ?>
                                         <?php if($ol["show_reserve_price"] == 1): ?><img src="<?php echo get_style_cdnurl();?>paimai/yunying/images/eye.png"><?php endif; ?>
                                     </td>
                                     <td style="color:#898b8a;">交易服务费</td>
                                     <td><?php echo ($ol["commision"]); ?></td>
                                 </tr>
                                 <tr>
                                     <td style="color:#898b8a;">拍卖最高价</td>
                                     <td><?php echo ($ol["bidding_best_price"]); ?></td>
                                     <td style="color:#898b8a;">交付服务费</td>
                                     <td><?php echo ($ol["transfer_fee"]); ?></td>
                                 </tr>
                                 </tbody>
                             </table><?php endif; endforeach; endif; else: echo "" ;endif; ?>
                </div>
            </div>
            <?php $car_status_arr = array('0'=>'待上传协议','1'=>'待审核','2'=>'审核失败','3'=>'审核驳回','4'=>'待拍卖','5'=>'拍卖中','6'=>'流拍','7'=>'待重拍','8'=>'交易失败','9'=>'交易成功','10'=>'待检测','11'=>'已退车') ?>
            <div class="yuList" style='display:none'>
                <h3 class="yonghu" style="margin-top:25px;">车辆状态跟踪</h3>
                <div class="yonghuText">
                    <h2>车辆编号：<?php echo ($car_info["sno"]); ?>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        <?php echo ($car_info["reg_city"]); ?> - <?php echo ($car_info["model"]); ?>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        当前状态：<?php echo ($car_status_arr[$car_info['car_status']]); ?>
                    </h2>
                    <ul>
                        <li class="clearfix" style="border-bottom:1px solid #ececec;font-weight:bolder;">
                            <em>发生时间</em>
                            <em>执行操作</em>
                            <em>操作人</em>
                        </li>
                        <?php if(is_array($car_action_log)): $i = 0; $__LIST__ = $car_action_log;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$cl): $mod = ($i % 2 );++$i;?><li class="clearfix">
                                <em><?php echo ($cl["createtime"]); ?></em>
                                <em><?php echo ($cl["action_name"]); ?></em>
                                <em><?php echo ($cl["emp_name"]); ?></em>
                            </li><?php endforeach; endif; else: echo "" ;endif; ?>
                    </ul>
                </div>
            </div>
            <div class="yuList" style='display:none'>
                <!--                <h3 class='cha'>基本信息</h3>-->
                <?php if($total_car > '1' ): ?><div class="presentation">
                        <span><a class="leftBtn"></a><a class="rightBtn"></a></span>
                        <div>
                            <ul class="clearfix">
                                <?php if(is_array($car_id_list)): foreach($car_id_list as $key=>$car_item): if($key == 0): ?><li name="<?php echo ($car_item["car_id"]); ?>" data-url="/Car/reportWithoutHeader/car_id/<?php echo ($car_item["car_id"]); ?>" class= "cuurent">报告<?php echo $total_car - $key;?></li>
                                    <?php else: ?>
                                        <li name="<?php echo ($car_item["car_id"]); ?>" data-url="/Car/reportWithoutHeader/car_id/<?php echo ($car_item["car_id"]); ?>">报告<?php echo $total_car - $key;?></li><?php endif; endforeach; endif; ?>
                            </ul>
                        </div>
                    </div><?php endif; ?>
                <div class="presentation-cont">
                    <iframe  frameborder="0" scrolling="no" id="external-frame" width="100%" height="3500"
                             src="/Car/reportWithoutHeader/car_id/<?php echo ($car_info['car_id']); ?>"></iframe>
                </div>
            </div>
        </div>
        <div class="yongBtn" style='width:170px;'>
            <input type="button"  class="quxiao" onclick="window.close()" value="关闭" />
        </div>
    </div>
</div>
<script type="text/javascript">

//历史报告头部切换
$(function(){
    $(".presentation span").hide();
    var oLiNum=$(".presentation ul li").length;
    var oLiW=$(".presentation ul li").width()*oLiNum;
    var num=0;
    if(oLiW>920){
        $(".presentation span").show();
    }else{
        $(".presentation span").hide();
    }
    $(".presentation span .leftBtn").hide();

    $(".presentation span .rightBtn").click(function(){
        $(".presentation span .leftBtn").show()
        num++;
        $(".presentation ul").animate({
            "marginLeft":-$(".presentation ul li").width()*num+"px"
        });
        var wMin=-(oLiNum-9)*$(".presentation ul li").width();
        if(wMin==-$(".presentation ul li").width()*num){
            $(".presentation span .rightBtn").hide();
        }
    })
    $(".presentation span .leftBtn").click(function(){
        num--;
        $(".presentation ul").animate({
            "marginLeft":-$(".presentation ul li").width()*num+"px"
        });
        $(".presentation span .rightBtn").show();
        if(-$(".presentation ul li").width()*num>=0){
            $(".presentation span .leftBtn").hide();

        }
    })
    $(".presentation ul li").click(function(){
        $(".presentation ul li").removeClass("cuurent");
        $(this).addClass("cuurent");
        var index=$(".presentation ul li").index(this);
        //alert($(this).attr("name"));
        var oUrl=$(this).attr("data-url");
        $("#external-frame").attr("src",oUrl);

        //var car_id = $(this).attr("name");
        $(".presentation-cont .jianCeBox").eq(index).show().siblings().hide();
    })
})


function setMethod(m){
    $("#service_method").val(m);
}

function setStatus(status){
    $("#business_status").val(status);
}

$(".other_remark").blur(function(){    
    $("#reserve_remark").val($(this).val());
});


$(".gencuur").click(function(){
    var str = $(this).children("font").html();
    $("#reserve_remark").val(str);
});
</script>
</body>
</html>